aes
{GGPLOT2}
Construct aesthetic mapping of a ggplot graph
c
{base}
Combine values/vectors into a vector
theme_classic
{GGPLOT2}
A minimalistic theme with no gridlines
sum
{base}
Get sum of numeric values or a vector
cor.test
{stats}
Test for Association/Correlation Between Paired Samples
read_excel
{readxl}
Read an Excel file
round
{base}
Rounds numbers
margin
{GGPLOT2}
Set margins around plot elements (used inside theme elements)
as.integer
{base}
Convert an object to integer values
lm
{stats}
Fit linear models using least squares
attach
{base}
Attach Set of R Objects to Search Path
recode
{dplyr}
Recode a variable
sd
{stats}
Get standard deviation of a vector
geom_smooth
{GGPLOT2}
Generates a smoothed conditional means curve / line
as.character
{base}
Coerce a vector to character
summarise
{dplyr}
collapse the dataset to a summary statistic. Usually used with group_by()
cut
{base}
Convert Numeric to Factor
with
{base}
evaluate expression in the context of a data frame
element_blank
{GGPLOT2}
This theme element draws nothing, and assigns no space
complete.cases
{stats}
Find Complete Cases
chisq.test
{stats}
Chi-Squared test (e.g. for cross-tabulations)
select
{dplyr}
Select columns from a tibble/data frame
mean
{base}
Get mean of a vector
setwd
{base}
Set Working Directory
prop.table
{base}
Transform frequency table into table of proportions
filter
{dplyr}
Filter out rows of a data frame according to logical vector
table
{base}
Obtain frequency table of a variable/cross-tabulation of two variables
replace
{base}
Replace elements in a vector
write.csv
{utils}
write a csv file to a data frame
element_text
{GGPLOT2}
Customise text in GGPLOT2
factor
{base}
Create a factor
ggplot
{GGPLOT2}
Create a ggplot graph
theme
{GGPLOT2}
Customize ggplot themes
data.frame
{base}
Create a data.frame from vectors
scale_y_continuous
{GGPLOT2}
Customise continuous y axis
read.csv
{utils}
Read a csv file to data frame. Specify stringsAsFactors = FALSE to keep all string columns as characters
factor
{base}
Create factor variables
labs
{GGPLOT2}
Customise labels in GGPLOT2
read_csv
{readr}
Read CSV files
correlation_matrix
{corrtable}
Create a formatted correlation matrix of variables
mutate
{dplyr}
Create new variables
geom_jitter
{GGPLOT2}
Add randomly displaced points to reduce overplotting
summary
{base}
Obtain summary statistics or detailed regression output
library
{base}
Load an R package
matrix
{base}
Creates a matrix from the given set of values.
is.na
{base}
Check if a value is NA/elements of vector are NA
scale_x_continuous
{GGPLOT2}
Customise continuous x axis
pwr.r.test
{pwr}
Power analysis for correlation tests
group_by
{dplyr}
Group tibble/data.frame by a factor variable. All further tidyverse operations are performed group-wise
as.numeric
{base}
Coerce a vector to numeric
vdem
{vdemdata}
V-Dem country-year dataset
geom_point
{GGPLOT2}
Generates a scatter plot
datasummary
{modelsummary}
Create customizable summary-statistics tables
The end!